import request from '@/utils/request'

//请求回来的数据
export interface RankModel {
    tabLists: RankListModel[],
    sceneId: number
}

//导航栏+标题
export interface RankListModel {
    id: number,
    name: string,
    position: number,
    sceneId: number,
    tabWraps: RankBannerModel[]
}
//导航栏
export interface RankBannerModel {
    tabId: number,
    id: number,
    name: string,
    position: number,
    rankingId: number
}


export default {

    getList(sceneId: 1|2) {
        return request.get<any, RankModel[]>(`/revision/rank/v4/rankTabs?sceneId=${sceneId}`)
    },

    getItem(rankingId:number){
        return request.get<any,any>(`/revision/rank/v4/element?rankingId=${rankingId}`)
    }

}